package Test1;

import java.util.HashMap;
import java.util.Scanner;
import java.util.Set;

public class TestDemo9 {
    public static void main(String[] args) {
        Scanner in = new Scanner(System.in);
        int n = in.nextInt();
        int ret = func(n);
        System.out.println(ret);

    }
    public static int func(int n) {
        int[] dp = new int[n+1];
        dp[0] = 1;
        dp[1] = 1;
        for (int i = 2; i <= n ; i++) {
            dp[i] = (dp[i-1]+dp[i-2]) % 1000000007;
        }
        return dp[n];
    }
    public int calculateMinimumHP(int[][] dungeon) {
        int m = dungeon.length;
        int n= dungeon[0].length;
        int[][] dp = new int[m+1][n+1];
        for (int i = 0; i <= n ; i++) {
            dp[m][i] = Integer.MAX_VALUE;   //初始化最下面一行
        }
        for (int i = 0; i <= m ; i++) {
            dp[i][n] = Integer.MAX_VALUE;   //初始化最后一列
        }
        dungeon[m][n-1] = dungeon[m-1][n] = 1;   //保证出来至少有一滴血
        for (int i = m-1; i >= 0 ; i--) {
            for (int j = n-1; j >= 0 ; j--) {
                dp[i][j] = Math.max(dp[i+1][j],dp[i][j+1]) - dungeon[m][n];
                dp[i][j] = Math.max(1,dp[i][j]);
            }
        }
        return dp[0][0];
    }
    public int massage(int[] nums) {
        int n = nums.length;
        if(n == 0) return 0;
        int[] f = new int[n];
        int[] g = new int[n];
        f[0] = nums[0];
        for (int i = 1; i < n; i++) {
            f[i] = g[i-1] + nums[i];
            g[i] = Math.max(f[i-1],g[i-1]);
        }
        return Math.max(f[n-1],g[n-1]);
    }
}
